<script language="javascript">
	function validar()
	{
		var validate=true;
		var msj="Estimado Usuario, verifique los siguientes campos:\n";
		var regexp;
		
		//validando formulario
		//campo alfabetico
		regexp = /\w+/;
		if(document.getElementById('claveActual').value.search(regexp))
		{
			msj=msj+"- Clave Actual\n ";
			validate=false;
		}
		//campo alfabetico
		regexp = /\w+/;
		if(document.getElementById('clave').value.search(regexp))
		{
			msj=msj+"- Nueva Clave\n ";
			validate=false;
		}
		//campo alfabetico
		regexp = /\w+/;
		if(document.getElementById('clave2').value.search(regexp))
		{
			msj=msj+"- Repeticion Nueva Clave\n ";
			validate=false;
		}
		if (!validate)
		{
			alert(msj);
			return false;		
		}
		else if(document.getElementById('clave').value!=document.getElementById('clave2').value)
		{
			alert("La clave nueva no concuerda.");
			return false;
		}
		else
		{
			return true;
		}
	}
</script>
<form name="formulario" method="post" action="usuario/cambiarClave" onSubmit="return validar();">
	<input name="caso" id="caso" type="hidden" value='resetear'/>
	<table align="center" border="0" cellpadding="2" cellspacing="2" width="98%">
		<tr><td class="separator" colspan="2">&nbsp;</td></tr>
		<tr><td class="separator" colspan="2">&nbsp;</td></tr>
		<tr>
			<td class="celBlanca" width="45%"><div align="right">&nbsp;Clave Actual&nbsp;<span style="color:red;">*</span></div></td>
			<td class="celBlancaFin" width="55%">
				&nbsp;<input type="password" name="claveActual" id="claveActual" value="" size="30" maxlength="10"/>
			</td>
		</tr>
		<tr>
			<td class="celBlanca"><div align="right">&nbsp;Nueva Clave&nbsp;<span style="color:red;">*</span></div></td>
			<td class="celBlancaFin">
				&nbsp;<input type="password" name="clave" id="clave" value="" size="30" maxlength="10"/>
			</td>
		</tr>
		<tr>
			<td class="celBlanca"><div align="right">&nbsp;Repetici&oacute;n Nueva Clave&nbsp;<span style="color:red;">*</span></div></td>
			<td class="celBlancaFin">
				&nbsp;<input type="password" name="clave2" id="clave2" value="" size="30" maxlength="10"/>
			</td>
		</tr>
		<tr><td class="separator" colspan="2">&nbsp;</td></tr>					
		<tr>
			<td colspan="2" align="center">
				<div align="center">
					<input type="submit" name="btnGuardar" value="Guardar" class="boton">
				</div>
			</td>
		</tr>
		<tr><td class="separator" colspan="2">&nbsp;</td></tr>
	</table>
</form>